home *** CD-ROM | disk | FTP | other *** search
- unit SDropDemo2;
- {$A+,B-,G+,H+,O+,J-,T+,U-,V+,W-,X+} //Set up compiler
- {$D-,L-,Q-,R-,Y-} //Comment out to debug
-
- interface
-
- uses
- Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs,
- StdCtrls, ExtCtrls;
-
- type
- TfrmDropEdit = class(TForm)
- Panel1: TPanel;
- rgColor: TRadioGroup;
- Label1: TLabel;
- procedure rgColorClick(Sender: TObject);
- private
- { Private declarations }
- public
- { Public declarations }
- end;
-
- var
- frmDropEdit: TfrmDropEdit;
-
- implementation
-
- uses SDropDemo1;
-
- {$R *.DFM}
-
- procedure TfrmDropEdit.rgColorClick(Sender: TObject);
- begin
- With frmDropDemo.SDropEdit1 do begin
- Case rgColor.ItemIndex of
- 0: begin Color:=clRed; Font.Color:=clWhite; Text:='Red'; end;
- 1: begin Color:=clGreen; Font.Color:=clWhite; Text:='Green'; end;
- 2: begin Color:=clBlue; Font.Color:=clWhite; Text:='Blue'; end;
- 3: begin Color:=clFuchsia; Font.Color:=clBlack; Text:='Purple'; end;
- 4: begin Color:=clYellow; Font.Color:=clBlack; Text:='Yellow'; end;
- 5: begin Color:=$000080FF; Font.Color:=clBlack; Text:='Orange'; end;
- end; // Case
- CloseForm; end;
- end;
-
-
- end.
-